<template>
  <div>
<h2>门店列表展示</h2>
<table border="1">
  <tr>
    <td>门店昵称</td>
    <td>门店地址</td>
    <td>联系方式</td>
    <td>门店照片</td>
    <td>营业时间</td>
    <td>休息时间</td>
    <td>门店类型</td>
  </tr>
  <tr v-for="item in list">
    <td>{{ item.name}}</td>
    <td>{{ item.address }}</td>
    <td>{{ item.phone }}</td>
    <td>
      <img src="../pic/QQ图片20240222105940.jpg" width="50" height="50">
    </td>
    <td>{{ item.sdate }}</td>
    <td>{{ item.edate }}</td>
    <td>{{ item.type }}</td>
  </tr>
</table>
共有<span>3</span>条
每页显示<span>2</span>条
当前为第<span>1/2</span>页
<input type="button" value="首页">
<input type="button" value="上一页">
<input type="button" value="下一页">
<input type="button" value="尾页">
  </div>
</template>

<script setup lang="ts">
import { reactive,toRefs,onMounted } from 'vue';
import axios from 'axios';
import { useRoute,useRouter } from 'vue-router';
let route=useRoute();
let router=useRouter();
let data=reactive({
  state:{
  
  },
  list:[]
})
let {state,list}=toRefs(data)
onMounted(()=>{
  Show()
})
function Show()
{
  axios({
    url:'/api/MenDian/GetMenDians',
    method:'get',
    
  })
  .then(res=>{
    list.value=res.data.data
  })
  .catch(err=>{

  })
}
</script>

<style scoped>

</style>